<template>
  <div class="mybody">
    <div class="content">
      <div class="navbar">
        <van-nav-bar
          fixed
          title="电影票"
          left-text="返回"
          left-arrow
          @click-left="$router.go(-1)"
        />
      </div>
      <div class="wrap">
        <!-- <div class="filmCount">
        <span>共{{ count }}部</span>
         <span>共{{  }}部</span>
      </div> -->
        <!-- <van-divider /> -->
        <order-item
          v-for="item in orderList"
          :key="item.index"
          :order="item"
        ></order-item>
        <div class="support"></div>
      </div>
    </div>
  </div>
</template>

<script>
import OrderItem from "@/components/order_item.vue";

export default {
  components: {
    "order-item": OrderItem,
  },
  data() {
    return {
      count: 1,
      orderList: [],
    };
  },
  mounted() {
    // 发送http请求, 加载相应id的详情数据:  /detail
    this.axios.get(`/order/selectOrder`).then((res) => {
      console.log(res);
      this.orderList = res.data;
      console.log("订单数据", this.orderList);
    });
  },
  methods: {},
};
</script>

<style scoped>
.mybody {
  height: 39rem;
  /* background-size: 100% 100%; */
  background-color: rgb(250, 248, 248);
}
.goods-card {
  margin: 0;
  background-color: white;
}

.support {
  height: 50px;
}
.wrap {
  margin-top: 45px;
}
.filmCount {
  margin-left: 15px;
  /* margin: ; */
  margin-bottom: 5px;
  font-size: 0.8rem;
  color: rgb(164, 165, 167);
}
.navbar /deep/ .van-nav-bar .van-icon {
  color: black;
}
.navbar /deep/ .van-nav-bar .van-nav-bar__text {
  color: black;
}
</style>
